package com.jtbd.config;

import com.jtbd.domain.Dictionary;
import com.jtbd.service.DictionaryService;
import jakarta.annotation.PostConstruct;
import jakarta.annotation.Resource;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.context.annotation.Configuration;

import java.util.List;

@Configuration
public class SystemDictionaryConfig {
    private static final Logger log = LoggerFactory.getLogger(SystemDictionaryConfig.class);
    @Resource
    private DictionaryService dictionaryService;

    @PostConstruct
    public void init() {
        List<Dictionary> dictionaryList = dictionaryService.getDictionaryList();
        log.info("初始化系统字典数据:{}", dictionaryList);
    }
}
